var queryParams = getQueryParams();
console.log(queryParams);
if(queryParams.js_sdk){
    loadScript(queryParams.js_sdk, function(err) {
        if (err) {
            console.error('加载出错');
        } else {
            console.log('加载成功');
            feihuo_login(queryParams);
        }
    });
}

//登录
function feihuo_login(queryParams){
    queryParams.cid = cid;
    queryParams.gid = gid;
    faXingLogin(queryParams);
}

function getQueryParams() {
    var urlParams = new URLSearchParams(window.location.search);
    var params = {};
    for (var param of urlParams.entries()) {
        params[param[0]] = param[1];
    }
    return params;
}



function feihuo_creterole(data){
    $.post(feihuo_creteroleUlr,data,function(info) {
        console.log("飞火创建角色结果:",info);
    });
}



function feihuo_pay(data){
    console.log("feihuo：",data);

    window[queryParams.js_sdk_name].pay(data);
}
